package sc.common.sftp;

import com.jcraft.jsch.UserInfo;

public class JschUserInfo implements UserInfo {

    public JschUserInfo(String password) {
        super();
        this.password = password;
    }

    String password;

    @Override
    public String getPassphrase() {
        System.out.println("getPassphrase");
        return null;
    }

    @Override
    public String getPassword() {
        System.out.println("getPassword: " + password);
        return password;
    }

    @Override
    public boolean promptPassphrase(String arg0) {
        System.out.println("promptPassphrase: " + arg0);
        return false;
    }

    @Override
    public boolean promptPassword(String arg0) {
        System.out.println("promptPassword: " + arg0);
        return true;
    }

    @Override
    public boolean promptYesNo(String arg0) {
        System.out.println("promptYesNo: " + arg0);
        return true;
    }

    @Override
    public void showMessage(String arg0) {
        System.out.println("showMessage: " + arg0);
    }

}
